# coding:utf-8

from celery import Celery
from launch.libs.yuntongxun.SendTemplateSMS import CCP

# 定义celery对象
celery_app = Celery("ihome", broker="redis://:990518@127.0.0.1:6379/1")


@celery_app.task
def send_sms(to, datas, temp_id):
    """发送短信异步任务"""
    ccp = CCP()
    ccp.send_template_sms(to, datas, temp_id)
